package uk.co.agileworks.bidpirate.test;

import org.joda.time.DateTime;

import uk.co.agileworks.bidpirate.model.Bid;
import uk.co.agileworks.bidpirate.model.CurrencyAndPrice;
import uk.co.agileworks.bidpirate.model.Item;
import uk.co.agileworks.bidpirate.model.Region;
import uk.co.agileworks.bidpirate.model.Status;
import uk.co.agileworks.bidpirate.model.User;

public final class DataSet {

	private static final double PRICE_ITEM1 = 1.00;
	private static final double PRICE_ITEM2 = 2.00;
	private static final double MAX_BID1 = 1.00;
	private static final double MAX_BID2 = 2.00;
	
	private Bid bid1, bid2;
	private Item item1, item2;
	private User user1, user2;

	public DataSet() {

		item1 = new Item();
		item1.setItemNumber(1L);
		item1.setDescription("The La's CD");
		item1.setImageUrl("images/thelas.jpg");
		item1.setCurrencyAndPrice(new CurrencyAndPrice("GBP", PRICE_ITEM1));
		item1.setEndTime(new DateTime("2016-02-25T12:30:52.000+00:00"));

		item2 = new Item();
		item2.setItemNumber(2L);
		item2.setDescription("Xmas Cake");
		item2.setImageUrl("images/cake.jpg");
		item2.setCurrencyAndPrice(new CurrencyAndPrice("US $", PRICE_ITEM2));
		item2.setEndTime(new DateTime("2016-12-25T12:30:52.000+00:00"));
		item2.setBuyItNow(true);

		user1 = new User();
		user1.setId(1L);
		user1.setUsername("capn_mike");
		user1.setPassword("pieces0f8");
		user1.setRegion(Region.UK);

		user2 = new User();
		user2.setId(2L);
		user2.setUsername("benbear");
		user2.setPassword("sparky");
		
		bid1 = new Bid();
		bid1.setId(1L);
		bid1.setMaxBid(MAX_BID1);
		bid1.setGroup("THELAS");
		bid1.setItem(item1);
		bid1.setUser(user1);
		bid1.setStatus(Status.ACTIVE);

		bid2 = new Bid();
		bid2.setId(2L);
		bid2.setMaxBid(MAX_BID2);
		bid2.setItem(item2);
		bid2.setUser(user2);
		bid2.setStatus(Status.UNSAVED);
	}

	public Bid getBid1() {
		return bid1;
	}

	public Bid getBid2() {
		return bid2;
	}

	public Item getItem1() {
		return item1;
	}

	public Item getItem2() {
		return item2;
	}

	public User getUser1() {
		return user1;
	}

	public User getUser2() {
		return user2;
	}

}
